package sz.szsmk.citizencard.util.zxyh;

import android.content.Context;
import android.widget.TextView;

import com.jakewharton.rxbinding.widget.TextViewEditorActionEvent;

import org.w3c.dom.Text;

import sz.szsmk.citizencard.R;

public class ResourceStyleUtils {


    public static void setMetrolLineBack(Context context,TextView textView){
        String text=textView.getText().toString();
        if(text.contains("1号线")){
          textView.setBackground(context.getResources().getDrawable(R.drawable.label_metro_line1_bg));
        }else if(text.contains("2号线")){
            textView.setBackground(context.getResources().getDrawable(R.drawable.label_metro_line2_bg));
        }else if(text.contains("3号线")){
            textView.setBackground(context.getResources().getDrawable(R.drawable.label_metro_line3_bg));
        }else if(text.contains("4号线")){
            textView.setBackground(context.getResources().getDrawable(R.drawable.label_metro_line4_bg));
        }else if(text.contains("在建")){
            textView.setBackground(context.getResources().getDrawable(R.drawable.label_metro_line_building_bg));
        }else {
            textView.setTextColor(context.getResources().getColor(R.color.color_2184FA));
        }


    }
}
